home *** CD-ROM | disk | FTP | other *** search
-
- // JavaScript wrapper for r3font.h
- // Auto generated file, do not modify by hand
- // Copyright ⌐ 2004, Realsoft Graphics Oy
-
- var R3_FONT_H = 1;
- include("oops/r3root.js")
-
-
- var R3CLID_FONT = 11;
-
-
-
-
- // Description: Find length of given string in pixels
- // Returns: Integer, length
- // p3: String, string whose length is to be measured
-
- R3FM_GETSTRLENGTH = 11000;
-
- function mR3FM_GETSTRLENGTH(p3) {
- return DoA(this.r3obj, 11000, p3, R3TID_STRING, 0);
- }
-
- // Description: Prepare font for fetching outline curves.
- // Returns: Boolean, true if succeeded. Otherwise the R3RA_Error can
- // p3: Tag[], R3RA_Error.
-
- R3FM_BEGINOUTLINE = 11001;
-
- function mR3FM_BEGINOUTLINE(p3) {
- return Do(this.r3obj, 11001, p3, R3TID_TAG, R3TNF_ARRAY);
- }
-
- // Description: End outline char session.
-
- R3FM_ENDOUTLINE = 11002;
-
- function mR3FM_ENDOUTLINE() {
- DoA(this.r3obj, 11002, 0, R3TID_INTEGER, 0);
- }
-
- // Description: These methods are needed for fetching geometry of outline fonts. Not all fonts support
- // this feature.
- // Returns: Boolean, true if character outline was succesfully fetched.
- // p1: Object, target object which can read outline description
- // p2: Integer, method with which the target object is called
- // p3: Integer, character to be outlined
-
- R3FM_OUTLINECHAR = 11003;
-
- function mR3FM_OUTLINECHAR(p1, p2, p3) {
- return DoA3(this.r3obj, 11003, p1, R3TID_OBJECT, 0, p2, R3TID_INTEGER, 0, p3, R3TID_INTEGER, 0);
- }
-
-
-
-
- R3FA_Font = 11500;
- function SetR3FA_Font(value) {
- R3Set(this.r3obj, R3FA_Font, value, R3TID_STRING, 0);
- }
-
- function GetR3FA_Font() {
- return R3Get(this.r3obj, R3FA_Font, R3TID_STRING, 0);
- }
-
- R3FA_Size = 11501;
- function GetR3FA_Size() {
- return R3Get(this.r3obj, R3FA_Size, R3TID_INTEGER, 0);
- }
-
- R3FA_Ascent = 11504;
- function GetR3FA_Ascent() {
- return R3Get(this.r3obj, R3FA_Ascent, R3TID_INTEGER, 0);
- }
-
- R3FA_Descent = 11505;
- function GetR3FA_Descent() {
- return R3Get(this.r3obj, R3FA_Descent, R3TID_INTEGER, 0);
- }
-
- R3FA_XFont = 11506;
- function GetR3FA_XFont() {
- return R3ToJS(R3Get(this.r3obj, R3FA_XFont, R3TID_OBJECT, 0));
- }
-
- var R3FA_Italic = 11508; // Boolean
- var R3FA_Bold = 11509; // Boolean
- var R3FA_Underline = 11510; // Boolean
- var R3FA_Template = 11511; // Object
- var MAX_FONTNAMELEN = 80;
-
-
- function r3Font () {
- this.base = r3God;
- if(arguments.length) {
- this.base(R3CLID_FONT, arguments);
- }
- // Methods
- this.GETSTRLENGTH=mR3FM_GETSTRLENGTH;
- this.BEGINOUTLINE=mR3FM_BEGINOUTLINE;
- this.ENDOUTLINE=mR3FM_ENDOUTLINE;
- this.OUTLINECHAR=mR3FM_OUTLINECHAR;
-
- // Attributes
- this.GetFont=GetR3FA_Font;
- this.SetFont=SetR3FA_Font;
- this.GetSize=GetR3FA_Size;
- this.GetAscent=GetR3FA_Ascent;
- this.GetDescent=GetR3FA_Descent;
- this.GetXFont=GetR3FA_XFont;
- }
-
- r3Font.prototype=new r3Root;
- // r3font.h_H